<%@ Page Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" Theme="Default" 
    EnableTheming="true" CodeFile="ReturnBook.aspx.cs" Inherits="ReturnBook" 
    Title="Dr. Yurttas' Office Library &mdash; Return Books" %>
<asp:Content ID="ContentAdmin" ContentPlaceHolderID="MasterContentAdmin" Runat="Server">
    <asp:LoginView ID="LoginViewAdmin" runat="server">
        <RoleGroups>
            <asp:RoleGroup Roles="admin">
                <ContentTemplate>
                    <asp:Panel runat="server" ID="byIsbnPanel" DefaultButton="returnButton" Width="300px">
                        <table border="0">
                            <tr>
                                <td align="center" style="font-weight: bold; font-size: 0.9em; 
                                    color: white; background-color: #5d7b9d" colspan="3">Return by ISBN and Username:</td>
                            </tr>
                            <tr>
                                <td style="width: 150px;"><asp:Label ID="returnLabel" runat="server" 
                                    Text="Book ISBN:"></asp:Label></td>
                                <td style="width: 150px;"><asp:TextBox ID="givenBookid" runat="server">
                                </asp:TextBox></td>
                                <td><asp:Label Width="10px" runat="server" ID="star1" ForeColor="#FF0000">
                                </asp:Label></td>
                            </tr>
                            <tr>
                                <td style="width: 150px;"><asp:Label ID="Label1" runat="server" 
                                    Text="Student Username"></asp:Label></td>
                                <td style="width: 150px;"><asp:TextBox ID="givenUsername" runat="server">
                                </asp:TextBox></td>
                                <td><asp:Label Width="10px" runat="server" ID="star2" ForeColor="#FF0000">
                                </asp:Label></td>
                            </tr>
                            <tr>
                                <td colspan="3" align="right" style="width: 100%;">
                                <asp:Button ID="returnButton" UseSubmitBehavior="false" OnClick="returnButton_Click"
                                Text="Return Book" runat="server" />
                            </td>
                            </tr>
                            <tr>
                                <td colspan="3" style="height: 10px;"><asp:Label runat="server" ID="error1" 
                                    ForeColor="#FF0000" Text=""></asp:Label></td>
                            </tr>
                        </table>
                    </asp:Panel>
                    <br />
                    <br />
                    <asp:Panel runat="server" ID="Panel1" DefaultButton="returnIdButton" Width="300px">
                        <table border="0">
                            <tr>
                                <td colspan="3" align="center" style="font-weight: bold; font-size: 0.9em; 
                                    color: white; background-color: #5d7b9d">Return by Request ID:</td>
                            </tr>
                            <tr>
                                <td style="width: 150px;"><asp:Label ID="Label4" runat="server" Text="Request ID:">
                                </asp:Label></td>
                                <td style="width: 150px;"><asp:TextBox ID="givenRequestid" runat="server">
                                </asp:TextBox></td>
                                <td><asp:Label Width="10px" runat="server" ID="star3" ForeColor="#FF0000">
                                </asp:Label></td>
                            </tr>
                            <tr>
                                <td colspan="3" align="right" style="width: 100%;"><asp:Button ID="returnIdButton" 
                                    OnClick="returnIdButton_Click" Text="Return Book" runat="server"
                                    UseSubmitBehavior="false" />
                            </td>
                            <tr>
                                <td colspan="3" style="height: 10px;"><asp:Label runat="server" ID="error2" 
                                    ForeColor="#FF0000" Text=""></asp:Label></td>
                            </tr>
                        </table>
                    </asp:Panel>
                </ContentTemplate>
            </asp:RoleGroup>
        </RoleGroups>
    </asp:LoginView>
</asp:Content>
<asp:Content ID="ContentUser" ContentPlaceHolderID="MasterContentUser" Runat="Server">
    <asp:LoginView ID="LoginViewUser" runat="server">
        <RoleGroups>
            <asp:RoleGroup Roles="user">
                <ContentTemplate>
                    <div style="width: 500px;">
                        To return a book simply take it back to Dr. Yurttas. To confirm the return you
                        will need to provide either your system Username (<span class="myname">
                        <asp:LoginName runat="server" ID="myName" /></span>) or the 
                        <span class="myname">Transaction ID</span> for the book you are returning.
                    </div>
                </ContentTemplate>
            </asp:RoleGroup>
        </RoleGroups>
    </asp:LoginView>
</asp:Content>
<asp:Content ID="ContentAnonymous" ContentPlaceHolderID="MasterContentAnonymous" Runat="Server">
    <asp:LoginView ID="LoginViewAnonymous" runat="server">
        <AnonymousTemplate>
            You do not have authorization to view this page.
        </AnonymousTemplate>
    </asp:LoginView>
</asp:Content>

